home *** CD-ROM | disk | FTP | other *** search
- /*
- Copyright © 1991-1995 by TopSoft Inc. All rights reserved.
-
- You may distribute this file under the terms of the TopSoft
- Artistic License, accompanying this package.
-
- This file was developed by George (ty) Tempel in connection with TopSoft, Inc..
- See the Modification History for more details.
-
- Product
- About Box
-
- FILE
- ABUEnvSpeechSynth.c
-
- NAME
- ABUEnvSpeechSynth.c, part of the ABox project source code,
- responsible for mix-in handling the AboutBox speech synthesis
- environment stuff.
-
- DESCRIPTION
- This file contains defines for the about box modules.
-
- DEVELOPED BY
- George (ty) Tempel netromancr@aol.com
- All code in this file, and its associated header file was
- Created by George (ty) Tempel in connection with the TopSoft, Inc.
- "FilterTop" application development, except where noted.
-
- CARETAKER - George (ty) Tempel <netromancr@aol.com>
- Please consult this person for any changes or suggestions to this file.
-
- MODIFICATION HISTORY
-
- dd mmm yy - xxx - patchxx: description of patch
- 10 June 94 - ty - Initial Version Created
- 20-july-94 - ty - initial version released
- 15-mar-95 - ty - added some fixes since the speech mgr detection
- didn't seem to work on the PowerMac 8100/80 at work,
- yet works fine on all 680x0 macs. Go figger...
- 27-apr-95 - ty - improved Gestalt checking
- 23-may-95 - ty - changes for compatibility with the CodeWarrior CW6
- release and the associated Universal Headers from Apple:
- most methods that returned references now have "Ref" at
- the end of their methods names to prevent possible collisions
- with datatypes and classes of the same name (older versions
- of the compiler didn't have a problem with this).
-
- */
-
- /*===========================================================================*/
-
- /*======= Segmentation directives ========*/
-
- #ifdef USE_MANUAL_SEGMENTATION
- #pragma segment ty
- #endif
-
- /*============ Header files ==============*/
-
- #include "ABUEnvSpeechSynth.h"
-
- /*=============== Globals ================*/
-
- /*================ CODE ==================*/
-
-
- /*=============================== ABUEnvSpeechSynth::ABUEnvSpeechSynth ================================*/
- ABUEnvSpeechSynth::ABUEnvSpeechSynth(void)
- {
- } // end ABUEnvSpeechSynth
-
-
- /*=============================== ABUEnvSpeechSynth::~ABUEnvSpeechSynth ================================*/
- ABUEnvSpeechSynth::~ABUEnvSpeechSynth(void)
- {
- } // end ~ABUEnvSpeechSynth
-
-
-
- /*=============================== ABUEnvSpeechSynth::IsPresent ================================*/
- Boolean ABUEnvSpeechSynth::IsPresent(void)
- {
- OSErr error = noErr;
-
- // begin here...
-
- error = this->CheckGestalt(gestaltSpeechAttr);
- #if GENERATINGCFM
- if ( (error == noErr) &&
- (this->Attribute(gestaltSpeechMgrLibPresent) ||
- this->Attribute(gestaltSpeechMgrPresent)) )
- #else
- if ( (error == noErr) &&
- (this->Attribute(gestaltSpeechMgrPresent)))
- #endif
- this->IndicatorRef() = true;
- else
- this->IndicatorRef() = false;
-
- return this->IndicatorRef();
- } // end IsPresent
-
-
-
- /*=============================== ABUEnvSpeechSynth::End ================================*/
- OSErr ABUEnvSpeechSynth::End(void)
- {
- OSErr error = noErr;
-
- // begin here...
- if (!this->IsPresent())
- return error;
-
- error = ::SpeakString((StringPtr)NULL);
-
- return error;
- } // end End
-
-